package com.yangyang.rpc.client;

import com.yangyang.rpc.server.SNoProtocol;
import org.apache.hadoop.conf.Configuration;
import org.apache.hadoop.ipc.RPC;

import java.io.IOException;
import java.net.InetSocketAddress;

public class SNoClient {

    public static void main(String[] args) throws IOException {
        SNoProtocol proxy = RPC.getProxy(
                SNoProtocol.class, SNoProtocol.versionID, new InetSocketAddress(8000), new Configuration());
        String name = proxy.echo("20210000000000");
        System.out.printf("学号：%s , 姓名 %s", "20210000000000", name);
    }

}
